/*
 * svn test
 */
#import <Foundation/Foundation.h>
#import <CoreData/CoreData.h>

@interface Database : NSObject <NSFetchedResultsControllerDelegate>  {
	
	NSManagedObjectModel *managedObjectModel;
    NSManagedObjectContext *managedObjectContext;	    
    NSPersistentStoreCoordinator *persistentStoreCoordinator;	
	
	NSFetchedResultsController *modelFetchedResultsController;
	NSFetchedResultsController *dataFetchedResultsController;
	NSFetchedResultsController *voiceFetchedResultsController;
}

@property (nonatomic, retain, readonly) NSManagedObjectModel *managedObjectModel;
@property (nonatomic, retain, readonly) NSManagedObjectContext *managedObjectContext;
@property (nonatomic, retain, readonly) NSPersistentStoreCoordinator *persistentStoreCoordinator;

@property (nonatomic, retain) NSFetchedResultsController *modelFetchedResultsController;
@property (nonatomic, retain) NSFetchedResultsController *dataFetchedResultsController;
@property (nonatomic, retain) NSFetchedResultsController *voiceFetchedResultsController;

- (NSString *)applicationDocumentsDirectory;
+ (Database *)getDatabase;
- (void)myInit;
-(void) saveChanges;
- (void)clearNews;
-(NSData *)findLastImage;
-(NSData *)findLastVoice;
@end
